package school;
public class Teacher {
    private String teacherId;
    private String teacherName;
    private String gender;
    private String courseId; // 所授课程编号

    public Teacher(String teacherId, String teacherName, String gender, String courseId) {
        this.teacherId = teacherId;
        this.teacherName = teacherName;
        this.gender = gender;
        this.courseId = courseId;
    }

    // Getter 和 Setter 方法
    public String getTeacherId() {
        return teacherId;
    }

    public void setTeacherId(String teacherId) {
        this.teacherId = teacherId;
    }

    public String getTeacherName() {
        return teacherName;
    }

    public void setTeacherName(String teacherName) {
        this.teacherName = teacherName;
    }

    public String getGender() {
        return gender;
    }

    public void setGender(String gender) {
        this.gender = gender;
    }

    public String getCourseId() {
        return courseId;
    }

    public void setCourseId(String courseId) {
        this.courseId = courseId;
    }

    @Override
    public String toString() {
        return "教师编号: " + teacherId + ", 教师姓名: " + teacherName + ", 性别: " + gender + ", 所授课程编号: " + courseId;
    }
}